<?php
/**
 * Created by PhpStorm.
 * User: lwh
 * Date: 2017/7/28
 * Time: 14:37
 */

?>
<html>
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <meta name="viewport" content="initial-scale=1.0, user-scalable=no" />
    <!-- meta使用viewport以确保页面可自由缩放 -->
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <!-- 引入 jQuery Mobile 样式 -->
    <link rel="stylesheet" href="css/jquery.mobile-1.4.5.min.css">
    <script type="text/javascript" src="js/jquery-1.7.min.js"></script>
    <!-- 引入 jQuery Mobile 库 -->
    <script type="text/javascript" src="js/jquery.mobile-1.4.5.min.js"></script>

    <title>测试接任务</title>
    <script type="text/javascript">

        $(document).ready(function(){
            var action = "controller/simpleAcceptTask.php";
            var data = {
                "userid":23,
                "taskid": 38,
                "currentstage": 2

































































,
                "starttime": "2017-07-28 14:40:00",
                "contracttime": "2017-08-28 15:40:00"
            };

            $.ajax({
                type: "POST",
                url: action,
                data: {data:JSON.stringify(data)},
                success: function(response)
                {
                    //var result = response.trim();
                    $("#message").html('<p class="error">输出内容：' +  response + '</p>');
                },
                error:function(request){
                    alert("connection error");
                }
            });
        });
    </script>
</head>
<body>

<div class="container">
    <div id="message"></div>
</div>
</body>
</html>

